package org.dromara.knowledgebase.core.document;


import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.io.Serial;
import java.io.Serializable;

/**
 * Entity基类
 *
 * @author Lion Li
 */
@Data
public class BaseDocument implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 文档ID[雪花]
     */
    @Id
    private String documentId;

    /**
     * 标题
     */
    @Field(type = FieldType.Text)
    private String title;

    /**
     * 创建者ID
     */
    @Field(type = FieldType.Long)
    private Long createBy;

    /**
     * 创建时间
     */
    @Field(type = FieldType.Long)
    private Long createTime;

    /**
     * 更新者ID
     */
    @Field(type = FieldType.Long)
    private Long updateBy;

    /**
     * 更新时间
     */
    @Field(type = FieldType.Long)
    private Long updateTime;

}
